package com.dragon.modules.yuegou.model.wallet;

import com.dragon.modules.yuegou.entity.wallet.CardPresentEntity;
import com.dragon.modules.yuegou.enums.wallet.CardPresentType;
import io.swagger.annotations.ApiModelProperty;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.time.LocalDateTime;
import java.util.List;

/**
 * 悦卡赠送模型类
 * 
 * @author pbuilder generated
 * @date 2019-06-03 15:20:35
 * @company sgy
 * @version 2.0
 * @see Length 长度限制
 * @see NotNull 对象非空
 * @see NotEmpty 字符串、集合、表、数组非空
 */
public class CardPresent extends CardPresentEntity {

	@ApiModelProperty("提取码列表")
	private List<CardExtractCode> extractCodeList;

	private String cardTitle;

	private String cardImg;

	public String getCardTitle() {
		return cardTitle;
	}

	public void setCardTitle(String cardTitle) {
		this.cardTitle = cardTitle;
	}

	public String getCardImg() {
		return cardImg;
	}

	public void setCardImg(String cardImg) {
		this.cardImg = cardImg;
	}

	public List<CardExtractCode> getExtractCodeList() {
		return extractCodeList;
	}

	public void setExtractCodeList(List<CardExtractCode> extractCodeList) {
		this.extractCodeList = extractCodeList;
	}

	/**
	 * 构造一个空悦卡赠送模型对象
	 */
	public CardPresent(){
		super();
	}
	
	/**
	 * 依据实体对象的信息构造一个悦卡赠送模型对象
	 * 
	 * @param entity 实体对象
	 */
	public CardPresent(CardPresentEntity entity){
		super(entity);
	}

	/**
	 * 依据其它对象的信息构造一个悦卡赠送模型对象
	 * 
	 * @param other 其它对象
	 */
	public CardPresent(CardPresent other){
		super(other);
	}


	@Override
	public String getId() {
    	return id;
    }

    /**
	 * 设置
	 * 
	 * @param id 
	 * @return 当前对象
	 */
    public CardPresent id(String id) {
    	this.id = id;
    	return this;
    }

	@Override
	public String getMemberId() {
    	return memberId;
    }

    /**
	 * 设置赠送ID
	 * 
	 * @param memberId 赠送ID
	 * @return 当前对象
	 */
    public CardPresent memberId(String memberId) {
    	this.memberId = memberId;
    	return this;
    }

	@Override
	public Integer getNum() {
    	return num;
    }

    /**
	 * 设置赠送数量
	 * 
	 * @param num 赠送数量
	 * @return 当前对象
	 */
    public CardPresent num(Integer num) {
    	this.num = num;
    	return this;
    }

	@Override
	public Integer getExtractedNum() {
    	return extractedNum;
    }

    /**
	 * 设置已提取数量
	 * 
	 * @param extractedNum 已提取数量
	 * @return 当前对象
	 */
    public CardPresent extractedNum(Integer extractedNum) {
    	this.extractedNum = extractedNum;
    	return this;
    }

	@Override
	public CardPresentType getType() {
    	return type;
    }

    /**
	 * 设置[枚举]赠送类型：0-赠送给好友-TO_FRIENDS、1-生成提取码-GENERATE_CODE
	 * 
	 * @param type [枚举]赠送类型：0-赠送给好友-TO_FRIENDS、1-生成提取码-GENERATE_CODE
	 * @return 当前对象
	 */
    public CardPresent type(CardPresentType type) {
    	this.type = type;
    	return this;
    }

	@Override
	public LocalDateTime getCreatedTime() {
    	return createdTime;
    }

    /**
	 * 设置提取时间
	 * 
	 * @param createdTime 提取时间
	 * @return 当前对象
	 */
    public CardPresent createdTime(LocalDateTime createdTime) {
    	this.createdTime = createdTime;
    	return this;
    }
}
